package com.whnk.model.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.whnk.model.mapper.DefTWorkflowMapper;
import com.whnk.model.domain.DefTWorkflow;
import com.whnk.model.service.IDefTWorkflowService;

/**
 * 本地工作流Service业务层处理
 * 
 * @author whnk
 * @date 2021-10-20
 */
@Service
public class DefTWorkflowServiceImpl implements IDefTWorkflowService 
{
    @Autowired
    private DefTWorkflowMapper defTWorkflowMapper;

    /**
     * 查询本地工作流
     * 
     * @param id 本地工作流主键
     * @return 本地工作流
     */
    @Override
    public DefTWorkflow selectDefTWorkflowById(Long id)
    {
        return defTWorkflowMapper.selectDefTWorkflowById(id);
    }

    /**
     * 查询本地工作流列表
     * 
     * @param defTWorkflow 本地工作流
     * @return 本地工作流列表
     */
    @Override
    public List<DefTWorkflow> selectDefTWorkflowList(DefTWorkflow defTWorkflow)
    {
        return defTWorkflowMapper.selectDefTWorkflowList(defTWorkflow);
    }

    /**
     * 新增本地工作流
     * 
     * @param defTWorkflow 本地工作流
     * @return 结果
     */
    @Override
    public int insertDefTWorkflow(DefTWorkflow defTWorkflow)
    {
        return defTWorkflowMapper.insertDefTWorkflow(defTWorkflow);
    }

    /**
     * 修改本地工作流
     * 
     * @param defTWorkflow 本地工作流
     * @return 结果
     */
    @Override
    public int updateDefTWorkflow(DefTWorkflow defTWorkflow)
    {
        return defTWorkflowMapper.updateDefTWorkflow(defTWorkflow);
    }

    /**
     * 批量删除本地工作流
     * 
     * @param ids 需要删除的本地工作流主键
     * @return 结果
     */
    @Override
    public int deleteDefTWorkflowByIds(Long[] ids)
    {
        return defTWorkflowMapper.deleteDefTWorkflowByIds(ids);
    }

    /**
     * 删除本地工作流信息
     * 
     * @param id 本地工作流主键
     * @return 结果
     */
    @Override
    public int deleteDefTWorkflowById(Long id)
    {
        return defTWorkflowMapper.deleteDefTWorkflowById(id);
    }



    /**
     * 工作流编码查询工作流
     * @param workflowCode
     * @return
     */
    @Override
    public DefTWorkflow selectDefTWorkflowByWorkflowCode(String workflowCode) {
        return defTWorkflowMapper.selectDefTWorkflowByWorkflowCode(workflowCode);
    }

    /**
     * 工作流编码查询工作流
     * @param defTWorkflowName
     * @return
     */
    @Override
    public DefTWorkflow selectDefTWorkflowByWorkflowName(String defTWorkflowName) {
        return defTWorkflowMapper.selectDefTWorkflowByWorkflowName(defTWorkflowName);
    }


}
